<template>
  <div class="info-card">
    <div class="add" :class="types[type]">较上日+{{ data.add }}</div>
    <div class="count" :class="types[type]">{{ data.count }}</div>
    <div class="label">{{ data.label }}</div>
  </div>
</template>

<script>

export default {
  name: "info-card",
  props: {
    data: {
      type: Object,
      default: () => {
        return {
          add: 0,
          count: 0,
          label: " "
        };
      }
    },
    type: {
      type: Number,
      default:0
    }
  },
    data() {
      return{
          types:["quezhen","yisi","zhiyu","siwang"]
      }
    }
};
</script>

<style lang="less" scoped>
.info-card {
  .add {
    font-size: 12px;
    padding-bottom: 5px;
  }
  .count {
    font-size: 24px;
    padding-bottom: 5px;
  }
  .label {
    font-size: 14px;
  }
}
.quezhen {
  color: #de5e5b;
}
.yisi {
  color: #e2931c;
}
.zhiyu {
  color: #61c197;
}
.siwang {
  color: #8e8e8e;
}
</style>
